﻿Public Class Subdomain_Editor

    
    Private Sub TextBox1_TextChanged(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles TextBox1.TextChanged
        If TextBox1.Text.Contains(".") = True Then
            If TextBox1.Text.ToLower.Contains("www.") = True Then
                TextBox1.BackColor = Color.Red
                Button3.Enabled = False
            Else

                TextBox1.BackColor = Color.GreenYellow
                Button3.Enabled = True
            End If
        Else
            TextBox1.BackColor = Color.Red
            Button3.Enabled = False
        End If
    End Sub

    Private Sub Button4_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button4.Click
        Try

       
            ListBox1.Items.Remove(ListBox1.SelectedItem)
        Catch ex As Exception

        End Try
    End Sub

    Private Sub Button3_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button3.Click
        ListBox1.Items.Add(TextBox1.Text)
    End Sub

    Private Sub Button1_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button1.Click

        For Each item As String In ListBox1.Items
            If item = "" Then
            Else
                If main.TextBox9.Text = "Click Me!" Then
                    main.TextBox9.Text = item
                Else
                    main.TextBox9.Text = main.TextBox9.Text + " " + item
                End If

                End If
        Next
        main.Show()
        Me.Close()
    End Sub
End Class